/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package deatax.game;

import deatax.game.map.Nature;
import deatax.game.map.Terrain;
import deatax.game.map.Tile;
import java.util.ArrayList;

/**
 *
 * @author pson
 */
public class Condition {
    
    private ArrayList<Terrain> terrain;
    private ArrayList<Nature> nature;
    
    
    public boolean met(Tile tile) {
        if (tile.getTerrain() == null || !terrain.contains(tile.getTerrain()) ) {
            return false;
        }
        if (tile.getNature() == null && nature.isEmpty()) {
            return true;
        }
        return nature.contains(tile.getNature());
    }
}
